<?php
 
error_reporting(0);
include "../comm/conn.php";
include "../comm/config.php";
include "check.php";
/*$open=file_get_contents(base64_decode("aHR0cDovL3BheS5kdW9kdW8xMjMuY29tL2NrbmljazIucGhw"));
if($open!=''){
function request_uri(){
if (isset($_SERVER['REQUEST_URI'])){
$uri = $_SERVER['REQUEST_URI'];
}else{
$uri = $_SERVER['PHP_SELF'];
}
return $uri;
}
$ckurl='http://'.$_SERVER['SERVER_NAME'].request_uri()."";
$checkcode=$_GET["checkcode"];
if($checkcode==""){
echo "<script language=javascript>window.location='".base64_decode("aHR0cDovL3BheS5kdW9kdW8xMjMuY29tL2NrbmljazIucGhwP25pY2s9").urlencode(MYUSERNICK)."&url=".$ckurl."<?php </script>";
$checkcode=$_GET["checkcode"];
}
if ($checkcode!=md5(MYUSERNICK.MYAPPKEY))
{
exit( base64_decode( "PGRpdiBzdHlsZT0ibWFyZ2luOjAgYXV0bzsiPuaCqOS4jeaYr+WkmuWkmua3mOWuneWuouaOiOadg+eUqOaIt++8jOivt+i0reS5sOato+eJiCA8YSBocmVmPSJodHRwOi8vcGF5LmR1b2R1bzEyMy5jb20iPjxmb250IGNvbG9yPSIjZmYwMDAwIj5odHRwOi8vcGF5LmR1b2R1bzEyMy5jb208L2ZvbnQ+PC9hPjwvZGl2Pg==") );
}
}*/
$id=$_GET["id"];
$link = mysql_connect($dbserver,$dbuser,$dbpass);
if (!$link) {
die("数据库链接出错: ".mysql_error());
}
else
{
mysql_query("set names utf8");
$sql="select * from ".$BIAOTOU."websetting where id=1";
mysql_select_db($dbname);
$rs = mysql_query($sql);
while ($row = mysql_fetch_array($rs))
{
$webtitle=$row["webtitle"];
$webdesc=$row["webdesc"];
$keyword=$row["keyword"];
$description=$row["description"];
$url=$row["url"];
$surl=$row["surl"];
$email=$row["email"];
$icp=$row["icp"];
$tongji=$row["tongji"];
$qq =$row["qq"];
$webnick =$row["webnick"];
$renzheng =$row["renzheng"];
$wjt=$row["wjt"];
$liebiao=$row["liebiao"];
$morensort=$row["morensort"];
$moban=$row["moban"];
$dengji1=$row["dengji1"];
$dengji2=$row["dengji2"];
$dengji3=$row["dengji3"];
$fxbl=$row["fxbl"];
$fxbl2=$row["fxbl2"];
$fxbl3=$row["fxbl3"];
$fxbl4=$row["fxbl4"];
$tgbl=$row["tgbl"];
$txxz=$row["txxz"];
$tixianje =$row["tixianje"];
$zhucesong=$row["zhucesong"];
$zhucesonglevel=$row["zhucesonglevel"];
$pagesize=$row["pagesize"];
$smtphost=$row["smtp_host"];
$smtpuser=$row["smtp_user"];
$smtppw=$row["smtp_pw"];
$smtpopen=$row["smtp_open"];
$hotword=$row["hotword"];
}
}
;echo '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">';
mysql_close($link);
?>
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>管理中心</title>
<link href="../comm/style.css" rel="stylesheet" type="text/css">
<style type="text/css">
<!--
table,tr,td { font-size:12px;}
table a { text-decoration:none; color:#FF6600}
table a:visted { color:#FF66CC; text-decoration:none}
.STYLE1 {font-weight: bold}
-->
</style>
</head>
<body topmargin="5" leftmargin="0">
<table width="98%" border="0" align="center" cellpadding="0" cellspacing="0" >
  <tr>
    <td height="282" valign="top"><table width="100%" border="0" align="center" cellpadding="0" cellspacing="0">
      <tr>
        <td>
          <table cellspacing="0" width="100%" height="207" style="border:1px  solid #DCEAF7;">
            <tr>
              <td height="30" colspan="2" bgcolor="E9F2FB" class="bigtext"><strong>&nbsp;<img src="images/arrow.gif" width="16" height="22" align="absmiddle" /> 网站基本信息设置</strong></td>
            </tr>
            <tr>
              <td width="100%" colspan="2" valign="top"><table width="100%" height="300" border="0" cellpadding="0" cellspacing="0">
                <tr>
                  <td valign="top"><form id="form1" name="form1" method="post" action="savewebsetting.php">
                    <br />
                    <table width="100%"  align="left" border=1 cellpadding=0 cellspacing=0
style="border-collapse: collapse" bordercolor="#dddddd">
<tr>
                        <td height="30" colspan="2" align="right" class="bigtext"><div align="left"><strong>网站全局设置</strong>：</div></td>
                        </tr>
       					<tr>
                        	<td width="129" height="30" align="right" class="bigtext">网站名称：</td>
                        	<td width="597" height="30" class="bigtext">&nbsp;
                          <input name="webtitle" type="text" value="<?php echo $webtitle;?>" size="40" class="btn3" style="width:300px" />
                          如：多多返利建站系统</td>
                      	</tr>
                      	<tr>
                        	<td width="129" height="30" align="right" class="bigtext">网站昵称：</td>
                        	<td width="597" height="30" class="bigtext">&nbsp;
                          <input name="webnick" type="text" value="<?php echo $webnick;?>" size="40" class="btn3" style="width:300px" />                          
                          如多多</td>
                      </tr>
					  <tr>
                        	<td width="129" height="30" align="right" class="bigtext">网站标题：</td>
                        	<td width="597" height="30" class="bigtext">&nbsp;
                          <input name="webdesc" type="text" value="<?php echo $webdesc;?>" size="40" class="btn3" style="width:300px" />
                          首页标题，如多多返利，让您赚钱如此简单！</td>
                      	</tr>
					  <tr>
                        <td width="129" height="30" align="right" class="bigtext">网站关键字：</td>
                        <td height="30" class="bigtext">&nbsp;
                          <input name="keyword" type="text" class="btn3" style="width:300px" value="<?php echo $keyword;?>" size="40" maxlength="100" />
                          采用半角 , 隔开</td>
                      </tr>
					   <tr>
                        <td width="129" height="30" align="right" class="bigtext">网站描述：</td>
                        <td height="30" class="bigtext">&nbsp;
                          <textarea name="description" cols="40" rows="3" class="btn3" id="description" style="width:400px"><?php echo $description;?></textarea></td>
                      </tr>
					  <tr>
                        <td width="129" height="30" align="right" class="bigtext">网站（全）：</td>
                        <td height="30" class="bigtext">&nbsp;
                          <input name="url" type="text" id="url" value="<?php echo $url;?>" size="40" class="btn3" style="width:300px" />
                          如 www.duoduo123.com                          不带http:// 后面不带/</td>
                      </tr>
					   <tr>
                        <td width="129" height="30" align="right" class="bigtext">站长email：</td>
                        <td height="30" class="bigtext">&nbsp;
                          <input name="email" type="text" id="email" value="<?php echo $email;?>" size="40"  class="btn3" style="width:300px" /></td>
                      </tr>
					   <tr>
                        <td width="129" height="30" align="right" class="bigtext">icp备案号：</td>
                        <td height="30" class="bigtext">&nbsp;
                          <input name="icp" type="text" id="icp" value="<?php echo $icp;?>" size="40"  class="btn3" style="width:300px" />
                          &nbsp;<a href="http://www.miibeian.gov.cn/publish/query/indexFirst.action" target="_blank">查询</a></td>
                      </tr>
					   <tr>
                        <td width="129" height="30" align="right" class="bigtext">站长qq：</td>
                        <td height="30" class="bigtext">&nbsp;
                          <input name="qq" type="text" id="qq" value="<?php echo $qq;?>" size="40"  class="btn3" style="width:300px" /></td>
                      </tr>
					  <tr>
					    <td width="129" height="30" align="right" class="bigtext">网站域名：</td>
					    <td height="30" class="bigtext">&nbsp;
					      <input name="surl" type="text" id="surl" value="<?php echo $surl;?>" size="40"  class="btn3" style="width:300px" />
					      如 duoduo123.com 不带http://</td>
					    </tr>
					  <tr>
                        <td width="129" height="30" align="right" class="bigtext">伪静态开关：</td>
                        <td height="30" class="bigtext">&nbsp;
                          <label>
                          <select name="wjt">
                            <option value="1" <?php if($wjt=="1") echo "selected";?>>开启</option>
                            <option value="0" <?php if($wjt=="0") echo "selected";?>>关闭</option>
                          </select>
                          请确认您的主机支持伪静态，否则不要开启。                          </label></td>
                      </tr>
					  <tr>
                        <td width="129" height="30" align="right" class="bigtext">默认列表样式：</td>
                        <td height="30" class="bigtext">&nbsp;
                          <select name="liebiao">
                            <option value="1" <?php if($liebiao=="1") echo "selected"; ?>>大图片横排</option>
                            <option value="0" <?php if($liebiao=="0") echo "selected"; ?>>小图片列表</option>
                                </select></td>
                      </tr>
					   <tr>
                        <td width="129" height="30" align="right" class="bigtext">商品页每页显示：</td>
                        <td height="30" class="bigtext">&nbsp;
                         <input name="pagesize" type="text" size="20" maxlength="4" class="btn3" style="width:100px" value="<?php echo $pagesize?>"/>
                         件商品 (注意：最多不超过40) </td>
                      </tr>
					  <tr>
                        <td width="129" height="30" align="right" class="bigtext">默认淘宝商品关键字：</td>
                        <td height="30" class="bigtext">&nbsp;
                         <input name="hotword" type="text" size="20" maxlength="4" class="btn3" style="width:100px" value="<?php echo $hotword?>"/>
                         必填，不然可能调不出数据。例如：女装 </td>
                      </tr>
					   <tr>
                        <td width="129" height="30" align="right" class="bigtext">默认排列顺序：</td>
                        <td height="30" class="bigtext">&nbsp;
                          <select name="morensort">
      <option value="commissionRate_desc" <?php if($morensort=="commissionRate_desc"){echo "selected";};?>>返现比率从高→低</option>
      <option value="commissionVolume_desc" <?php if($morensort=="commissionVolume_desc"){echo "selected";};?>>人气从高→低</option>
      <option value="commissionNum_desc" <?php if($morensort=="commissionNum_desc"){echo "selected";};?>>销量从高→低</option>
      <option value="price_desc" <?php if($morensort=="price_desc"){echo "selected";};?>>价格从高→低</option>
      <option value="price_asc" <?php if($morensort=="price_asc"){echo "selected";};?>>价格从低→高</option>
      <option value="credit_desc" <?php if($morensort=="credit_desc"){echo "selected";};?>>信用从高→低</option>
      <option value="delistTime_desc" <?php if($morensort=="delistTime_desc"){echo "selected";};?>>下架时间从高→低</option>
      <option value="delistTime_asc" <?php if($morensort=="delistTime_asc"){echo "selected";};?>>下架时间从低→高</option>
    </select></td>
                      </tr> <tr>
                        <td width="129" height="30" align="right" class="bigtext">默认模板文件：</td>
                        <td height="30" class="bigtext">&nbsp;
                     <select name="moban">
<?php
$dir = "../template/";
if (is_dir($dir)){
if ($dh = opendir($dir)){
while (($file = readdir($dh)) !== false){
if($file!="."&&$file!="..")
{
if(MOBAN==$file){
echo "<option value=".$file." selected>$file</option>";}
else
{echo "<option value=".$file.">$file</option>";}
}
}
closedir($dh);
}
};?>     
                          </select>
                     &nbsp;默认只提供一套 &nbsp;&nbsp;(请将模板文件夹放置到网站templates文件夹下) <a href="http://union.zhubajie.com/?u=2371018" target="_blank">威客定制</a> <a href="http://www.duoduo123.com/plus/view.php?aid=66" target="_blank">官方定制</a></td>
                      </tr>
					   <tr>
                        <td width="129" height="50" align="right" class="bigtext">统计代码：</td>
                        <td height="50" class="bigtext">&nbsp;
                          <textarea name="tongji" cols="60" rows="3" class="btn3" id="tongji" style="width:400px"><?php echo htmlspecialchars($tongji);?></textarea>
                          <a href="http://new.cnzz.com/user/reg.php?b951a832370420ba4a334e07b526d84a" target="_blank">CNZZ</a><a href="http://www.linezing.com/" target="_blank">&nbsp;&nbsp;&nbsp;量子</a>&nbsp;&nbsp;<a href="http://tongji.baidu.com/hm-web/welcome/login" target="_blank">百度</a></td>
                      </tr>
					  <tr>
                        <td width="129" height="50" align="right" class="bigtext">认证代码：</td>
                        <td height="50" class="bigtext">&nbsp;
                          <textarea name="renzheng" cols="60" rows="3"  id="renzheng" style="width:400px"><?php echo htmlspecialchars($renzheng);?></textarea>
                        （现已经停止申请）<a href="http://soft.duoduo123.com/help/inat/2010/0513/29.html" target="_blank"></a></td>
                      </tr>
					  <tr>
					  <td height="30" align="right" class="bigtext">会员等级设置：</td>
                        <td height="30" class="bigtext">&nbsp;黄金
                          <input name="dengji1" type="text" id="dengji1" value="<?php echo $dengji1;?>" size="10" maxlength="5" class="btn3" style="width:50px" />
                           点 白金
                           <input name="dengji2" type="text" id="dengji2" value="<?php echo $dengji2;?>" size="10" maxlength="5" class="btn3" style="width:50px" />
                           点 
钻石
                           <input name="dengji3" type="text" id="dengji3" value="<?php echo $dengji3;?>" size="10" maxlength="5" class="btn3" style="width:50px" />
点                           <span class="STYLE1">（一次成功的交易积1点成长值）</span></td>
                      </tr><tr>
                        <td height="30" align="right" class="bigtext">会员返现比率：</td>
                        <td height="30" class="bigtext">&nbsp;普通
                          <input name="fxbl" type="text" id="fxbl" value="<?php echo $fxbl*100;?>" size="10" maxlength="2" class="btn3" style="width:50px" />
                          %&nbsp;&nbsp;&nbsp;黄金
                          <input name="fxbl2" type="text" id="fxbl2" value="<?php echo $fxbl2*100;?>" size="10" maxlength="2" class="btn3" style="width:50px" />
%&nbsp;&nbsp;&nbsp;白金
<input name="fxbl3" type="text" id="fxbl3" value="<?php echo $fxbl3*100;?>" size="10" maxlength="2" class="btn3" style="width:50px" />
%&nbsp;&nbsp;&nbsp;钻石
<input name="fxbl4" type="text" id="fxbl4" value="<?php echo $fxbl4*100;?>" size="10" maxlength="2" class="btn3" style="width:50px" />
% <a href="http://bbs.duoduo123.com/read.php?tid=4417" target="_blank" style="color:#FF6600" >什么是会员等级</a></td>
                      </tr>
					  
                      <tr>
                        <td height="30" align="right" class="bigtext">推广佣金比率：</td>
                        <td height="30" class="bigtext">&nbsp;
                          <input name="tgbl" type="text" id="tgbl" value="<?php echo $tgbl*100;?>" size="10" maxlength="2" class="btn3" style="width:100px" />
                          %
  （填写0-100）如 10% 表示推广总佣金的10%，支付给推广人的部分</td>
                      </tr>
					   <tr>
                        <td height="30" align="right" class="bigtext">提现最低限额：</td>
                        <td height="30" class="bigtext">&nbsp;
                          <input name="tixianje" type="text" id="tixianje" value="<?php echo $tixianje;?>" size="10" maxlength="3" class="btn3" style="width:100px" /> 
                        元</td>
                      </tr>
                      <tr>
                        <td height="30" align="right" class="bigtext">提现金额必须是：</td>
                        <td height="30" class="bigtext">&nbsp;
                          <input name="txxz" type="text" id="txxz" value="<?php echo $txxz;?>" size="10" maxlength="4" class="btn3" style="width:100px" /> 
                        元的整数倍（如此处填写10，则用户账户有32.5元的话，最多只能提取30元。0表示不限制）</td>
                      </tr>
					  <tr>
                        <td height="30" align="right" class="bigtext">注册赠送金额：</td>
                        <td height="30" class="bigtext">&nbsp;
                          <input name="zhucesong" type="text" id="zhucesong" value="<?php echo $zhucesong;?>" size="10" maxlength="3" class="btn3" style="width:100px" /> 
                        元 慎重填写赠送金额，如需设置，请参考设置教程。</td>
                      </tr>
					  <tr>
                        <td height="30" align="right" class="bigtext">注册送成长值：</td>
                        <td height="30" class="bigtext">&nbsp;
                          <input name="zhucesonglevel" type="text" id="zhucesonglevel" value="<?php echo $zhucesonglevel;?>" size="10" maxlength="3" class="btn3" style="width:100px" /> 
                        点</td>
                      </tr>
                      <tr>
                        <td height="30" colspan="2" align="left" class="bigtext"><span class="bigtext" style="padding-left:27px; color:#FF0000">友情提示：①推广佣金比例+返现比例&lt;=90%。②注册赠送金额建议填“0”。</span></td>                        
                        </tr>
					  <tr><td height="30" colspan=2 class="bigtext"><div align="left"><strong>电子邮件设置</strong>（确认支持smtp）</div></td>
					  </tr>
					   <tr>
                        <td height="30" align="right" class="bigtext">smtp服务开关：</td>
                        <td height="30" class="bigtext">&nbsp;  <select name="smtpopen">
                            <option value="on" <?php if($smtpopen=="on") echo "selected";?>>开启</option>
                            <option value="off" <?php if($smtpopen=="off") echo "selected";?>>关闭</option>
                                                    </select>
                           关闭此服务所有的邮件服务都会失效 </td>
                      </tr>
					    <tr>
                        <td height="30" align="right" class="bigtext">smtp服务器地址：</td>
                        <td height="30" class="bigtext">&nbsp;
                          <input name="smtphost" type="text" id="smtphost" value="<?php echo $smtphost;?>" size="20" maxlength="30" class="btn3" style="width:200px" />
                          如：smtp.qq.com ，smtp.126.com</td>
                      </tr>
					    <tr>
                        <td height="30" align="right" class="bigtext">smtp服务器用户名：</td>
                        <td height="30" class="bigtext">&nbsp;
                          <input name="smtpuser" type="text" id="smtpuser" value="<?php echo $smtpuser;?>" size="20" maxlength="30" class="btn3" style="width:100px" />
                          您的邮箱用户名，如service@duoduo123.com</td>
                      </tr>
					    <tr>
                        <td height="30" align="right" class="bigtext">smtp服务器密码：</td>
                        <td height="30" class="bigtext">&nbsp;
                          <input name="smtppw" type="password" id="smtppw" value="<?php echo $smtppw;?>" size="20" maxlength="30" class="btn3" style="width:100px" /> 
                        您的邮箱密码                        </td>
                      </tr>
                      <tr>
                        <td height="30" align="right">&nbsp;</td>
                        <td height="30" class="bigtext">&nbsp;
                          <input type="submit" name="Submit" value=" 保 存 设 置 " /> 
                          &nbsp;&nbsp;&nbsp;<a href="http://www.duoduo123.com/help/V70/" target="_blank">建站帮助</a> </td>
                      </tr>
                    </table>
                    <br />
                  </form>
                  </td>
                </tr>
              </table></td>
            </tr>
          </table></td>
        </tr>
      
    </table></td>
  </tr>
</table>
<script src="http://soft.duoduo123.com/remote/facefiles/jquery-1.2.2.pack.js" type="text/javascript"></script>
<script src="http://soft.duoduo123.com/remote/facefiles/facebox.js" type="text/javascript"></script>
<link href="http://soft.duoduo123.com/remote/facefiles/facebox.css" media="screen" rel="stylesheet" type="text/css" />
<script type="text/javascript">
    jQuery(document).ready(function($) {
      $(\'a[rel*=facebox]\').facebox() 
    })
</script>
<div id="mydiv" style="display:none; font:12px; color:#666666;">
您好！只有购买了商业授权才能更改为自己的推广链接。未经官方授权可能会出现未知错误或自动还原PID设置。<br/><br/>
&nbsp;&nbsp;&nbsp;<a href="http://soft.duoduo123.com/buy/2010/0609/84.html" target="_blank">查询授权</a> &nbsp;&nbsp;&nbsp;   <a href="http://soft.duoduo123.com/pay" target="_blank">立即购买</a><br/>
<br/>
<span style="color:#FF0000; text-align:center">提示：通过自助购买授权 安装 设置仅需10分钟即可完成建站。方便、快捷、安全。<br/>
请认准官方域名“duoduo123.com”</span>
</div>
</body>
</html>
